home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Celestin Apprentice 5
/
Apprentice-Release5.iso
/
Source Code
/
C
/
Frameworks
/
Grant's CGI Framework 1.0b14
/
Util
/
LogUtil.h
< prev
next >
Wrap
C/C++ Source or Header
|
1996-04-12
|
2KB
|
81 lines
#pragma once
/*****
*
* LogUtil.c
*
* Logging functions
*
* This is a support file for "Grant's CGI Framework".
* Please see the license agreement that accompanies the distribution package
* for licensing details.
*
* Copyright ©1995,1996 by Grant Neufeld
* grant@acm.com
* http://arpp.carleton.ca/grant/mac/grantscgi/
*
*****/
#include "MyConfiguration.h"
#if kCompileWithLogSupport
#include "compiler_stuff.h"
/*** CONSTANTS ***/
#define kLogLinebreak '\r'
#define kLogLinebreakP "\p\r"
/*** FUNCTION PROTOTYPES ***/
OSErr LogStartup ( void );
OSErr LogQuit ( void );
OSErr LogFileOpen ( void );
OSErr LogFileClose ( void );
p_export OSErr LogFileFlush ( void );
/* coming soon? */
// OSErr LogWindowOpen ( void );
// OSErr LogWindowClose ( void );
p_export OSErr LogString ( const char * );
p_export OSErr LogStringP ( const StringPtr );
p_export OSErr LogStringAndSeparator ( const char *, char );
p_export OSErr LogStringAndSeparatorP ( const StringPtr, char );
#if kCompileWithDebugLogging
p_export OSErr LogStringDebug ( const char * );
p_export OSErr LogStringDebugP ( const StringPtr );
#else
#define LogStringDebug(s) (noErr)
#define LogStringDebugP(s) (noErr)
#endif /* kCompileWithDebugLogging */
/*** MACROS ***/
#define LogStringBreak(a) LogStringAndSeparator(a,kLogLinebreak)
#define LogStringBreakP(a) LogStringAndSeparatorP(a,kLogLinebreak)
#else /* if !kCompileWithLogSupport */
#define LogStartup(a) (noErr)
#define LogQuit(a) (noErr)
#define LogFileOpen(a) (noErr)
#define LogFileClose(a) (noErr)
#define LogFileFlush(a) (noErr)
#define LogString(a) (noErr)
#define LogStringP(a) (noErr)
#define LogStringAndSeparator(a) (noErr)
#define LogStringAndSeparatorP(a) (noErr)
#define LogStringDebug(s) (noErr)
#define LogStringDebugP(s) (noErr)
#define LogStringBreak(a) (noErr)
#define LogStringBreakP(a) (noErr)
#endif /* kCompileWithLogSupport */
/*** EOF ***/